from tools.request import send


def add(product_id='3', unique_id='11c60075', cart_num=1):
    # 请求方法
    method = 'POST'
    # 接口地址
    path = '/api/cart/add'
    # 请求body
    payload = {
        'productId': product_id,
        'cartNum': cart_num,
        'new': 0,
        'uniqueId': unique_id,
        'virtual_type': 0
    }
    # 调用方法发送接口
    return send(method, path, payload)


if __name__ == '__main__':
    print(add().text)
